<extend name="Base/common"/>
<block name="style">
    <style>
		body {
			background: #F7F7F7;
		}
		.breadcrumb{
            margin-bottom: 0px;
            padding-left:0;
            font-size: 18px;
        }
		.topic_title {
			color: #505050;
		}
		.topic_title_count {
			padding-top: 20px;
		}
		.topic_title {
			color: #626770;
			padding: 7px 15px;
		}
		.pull-right {
			float: right !important;
		}
		.topic_title_count p {
			font-size: 16px;
			margin-top: 16px;
			margin-right: 10px;
		}
		.topic_title p {
			font-size: 18px;
		}
		.post_text p {
			font-size: 16px;
			line-height: 1.65;
		}
		.post_text {
			background: #fff;
			padding: 20px;
			min-height: 450px;
			overflow: hidden;
			position: relative;
			font-size: 16px;
		}
		.board_classify p {
			margin: 10px 0px 0px 15px;
		}
		.board_classify p a {
			margin: 0 6px 6px 0;
			display: inline-block;
		}
		.board_classify a {
			line-height: 22px;
		}
		.board_classify a:hover {
			text-decoration: underline;
		}
		.board_classify span {
			color: #626770;
			font-size: 14px;
		}
		.side-block > div > div.last-child {
			padding-bottom: 20px;
		}
		.main-block {
			margin-bottom: 30px;
		}
		.main-block > div{
		    background: #fff;
            padding: 15px 30px;
		}
		.main-block > section {
			background: #fff;
			padding: 15px 0px;
		}

		.main-block > div.first-child {
			border-top: 5px solid #41b6d3;
		}

		.post_sort {
			border-bottom: 1px dashed #e9e9e9;
		}

		.list-group {
			padding-left: 0;
			margin-bottom: 0px;
			list-style: none;
		}
		.ot_post_list .list-inline > li {
			vertical-align: top;
			padding-left: 0;
			padding-right: 0;
			display: inline-block !important;
		}
		.list-inline > li {
			display: inline-block;
			padding-right: 5px;
			padding-left: 5px;
		}
		.ot-list-title {
			width: 86%;
		}
		.ot_post_topic {
			font-size: 16px;
			margin-bottom: 10px;
			padding-right: 15px;
		}
		.ot_post_info {
			color: #c2c2c2;
		}
		.ot_post_info a {
			color: #999999;
			cursor: pointer;
		}
		.ot_post_info span, .ot_post_info a {
			margin-right: 8px;
			font-size: 14px;
		}
		.list-group-item {
border: none;
}
.ot_post_list >li {
border-radius: 0;
margin-bottom: 0;
border-color: #fff;
border-bottom: 1px dashed #E9E9E9;
padding: 10px 12px 10px 30px;
position: relative;
}
		
		.side-block {
            margin-bottom: 30px;
        }
        .board_info {
            font-size: 16px;
        }
        .side-block > div {
            background: #fff;
            margin-bottom: 25px;
            color: #626770;
            border-top: 5px solid #DDDDDD;
        }
        .side-block > div.first-child {
            border-top: 5px solid #DDDDDD;
        }
        .side-block > div.last-child {
            margin-bottom: 0;
        }
        #sidebar h5 {
            position: fixed;
            top: 190px;
        }
        #sidebar .popover {
            z-index: 9;
        }
        .side-block > div > h4 {
            margin: 0;
            border-bottom: 2px solid #F7F7F7;
            height: 46px;
            line-height: 46px;
            font-weight: normal;
            padding-left: 20px;
        }
        .board_filter ul, .board_classify ul, .hot_discuss ul, .active_user ul {
            margin: 0 auto;
            padding: 10px 20px 0;
        }
        .list-circle-prefix {
            display: inline-block;
            border-radius: 5px;
            width: 5px;
            height: 5px;
            background: #CCC;
            vertical-align: top;
            margin-right: 8px;
            margin-top: 9px;
        }
    </style>
</block>
<block name="header">
    <div class="content_content container">
        <header class="row topic_title" id="overview">
            <div class="col-md-8 col-sm-8">
                <ol class="breadcrumb">
                    <li>
                        <a href="{:U('Index/index')}">首页</a>
                    </li>
                    <li class="active">
                        <a href="{:U('Article/lists/',array('category'=>$category['id']))}">{$category['title']}</a>
                    </li>
                </ol>
                <p class="category_description">
                    {$category['description']}
                </p>
            </div>
            <div class="col-md-4 topic_title pull-right topic_title_count">
                <p class="pull-right">
                    主题数：{$category['listCount']}
                </p>
            </div>
        </header>
    </div>
</block>

<block name="body">
    <div class="content_content container">
        <div class="row row-offcanvas row-offcanvas-right">
            <div class="col-xs-12 col-sm-8 col-md-8 topic_content main-block">
                <div class="post_sort clearfix first-child">
                    <div class="pull-left">
                        <select class="form-control">
                            <option>默认排序</option>
                        </select>
                    </div>
                    <div class="btn-group pull-right  btn-group-sm">
                        <a href="#" class="btn btn-default">全部</a>
                        <a href="#" class="btn btn-default ">精华</a>
                        <a href="#" class="btn btn-default ">零回复</a>
                    </div>
                </div>

                <section id="contents" class="clearfix">
                    <ul class="list-group ot_post_list">
                        <volist name="lists" id="list">
                            <li class="list-group-item <if condition="$i eq 1">first-child</if>">
                                <ul class="list-inline">
                                    <li class="avatar"></li>
                                    <li class="ot-list-title">
                                        <div class="ot_post_topic">
                                            <a href="{:U('Article/detail?id='.$list['id'])}" target="_blank">{$list.title}</a>
                                            <span class="ot_pith_item"></span>
                                        </div>
                                        <div class="ot_post_info">
                                            <a href="{:U('Article/lists?category='.get_category_name($list['category_id']))}" target="_blank">{$list.category_id|get_category_title}</a>| <a class="ot-list-author" href="#">{$list.uid|get_username}</a>

                                            <span>浏览：{$list.view}  回复：{$list.comment}</span>

                                            <span class="ot-list-time pull-right">{$list.create_time|date='m-d H:i',###}</span>
                                        </div>
                                    </li>
                                </ul>
                            </li>
                        </volist>
                    </ul>
                    <div class="onethink pagination pagination-right pagination-large">
                        <article:page cate="$category['id']" listrow="$category['list_row']" />
                    </div>
                </section>
            </div>
            
            <div class="col-md-4 col-xs-12 col-sm-4 sidebar-offcanvas side-block" id="sidebar" role="navigation">
                <div class="board_info first-child">
                    <h4>{$category['title']}</h4>
                    <if condition="$board">
                        <div class="board_classify first-child last-child">
                            <ul class="list-unstyled">
                                <volist name="board" id="bo">
                                    <li>
                                        <if condition="$bo['doc']">
                                            <span class="list-circle-prefix"></span><a href="{:U('Article/detail/',array('id'=>$bo['id']))}">{$bo['title']}</a>
                                            <else/>
                                            <span class="list-circle-prefix"></span><a href="{:U('Article/index/',array('category'=>$bo['id']))}">{$bo['title']}</a>
                                        </if>
                                    </li>
                                </volist>
                            </ul>
                        </div>
                    </if>
                </div>

                <div style="border:none"></div>
                <div class="hot_discuss">
                    <h4>热门讨论</h4>
                    <div class="board_classify first-child last-child">
                        <ul class="list-unstyled"></ul>
                    </div>
                </div>

            </div>
            
        </div>
    </div>
</block>